import http from '@/design/libs/request/request'

const BASE_URL = '/rebatenew/rebatecoupon'

export default {
  /**
   * 累计返券
   */
  // 根据会员卡号查询返券订单
  getorderbycard: data => http.post(BASE_URL + '/getorderbycard', data),
  // 根据订单号查询返券订单
  getorderbysaleno: data => http.post(BASE_URL + '/getorderbysaleno', data),
  // 提交小票
  rebatesubmitorders: data => http.post(BASE_URL + '/rebatesubmitorders', data),
  // 获取token
  rebatesendtoken: data => http.post(BASE_URL + '/rebatesendtoken', data),
  // 发券
  rebatecouponbytoken: data => http.post(BASE_URL + '/rebatecouponbytoken', data),
  // 失败或取消修改记录状态
  updateFailStatus: data => http.post(BASE_URL + '/updateFailStatus', data),

  /**
   * 其他
   */
  // 获取可返券订单（单笔返券）
  getRebateOrders: data => http.post(BASE_URL + '/getRebateOrders', data),
  // 发券 - 单笔返券
  rebatecouponDBFQbytoken: data => http.post(BASE_URL + '/rebatecouponDBFQbytoken', data),

  // 主题下各档次活动（满额返券/单笔返券）
  queryOperByScheduleId: data => http.post(BASE_URL + '/queryOperByScheduleId', data),

  // 获取可返券订单（多级满赠/满额返券）
  getRebateOrdersMZ: data => http.post(BASE_URL + '/getRebateOrdersMZ', data),
  // 今日活动消费总金额
  todayTotalAmount: data => http.post(BASE_URL + '/todayTotalAmount', data),
  // 发券 - 满额返券
  rebatecouponMEFQbytoken: data => http.post(BASE_URL + '/rebatecouponMEFQbytoken', data),

  // 主题下各档次活动（多级满赠 单笔/累计）
  queryDJMZOperByScheduleId: data => http.post(BASE_URL + '/queryDJMZOperByScheduleId', data),
  // 发券 - 累计多级满赠
  rebatecouponLJDJMZbytoken: data => http.post(BASE_URL + '/rebatecouponLJDJMZbytoken', data),
  // 发券 - 单笔多级满赠
  rebatecouponDBDJMZbytoken: data => http.post(BASE_URL + '/rebatecouponDBDJMZbytoken', data)
}

